package com.wt.struggle.goodbye.user

import android.os.Bundle
import android.support.v7.widget.DividerItemDecoration
import android.support.v7.widget.LinearLayoutManager
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import com.wt.struggle.goodbye.R
import com.wt.struggle.goodbye.base.ProV4Fragment
import com.wt.struggle.goodbye.info.NetInfo
import kotlinx.android.synthetic.main.collect_tie_fragment.*

class CollectFragment : ProV4Fragment() {
    override fun handler(what: Int, arg1: Int, netInfo: NetInfo) {
    }

    override fun createView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View {
        return inflater.inflate(R.layout.collect_tie_fragment, container, false)
    }

    override fun onActivityCreated(savedInstanceState: Bundle?) {
        super.onActivityCreated(savedInstanceState)

        initAdapter()

        send!!.getCollectList(1, handler)
    }


    private fun initAdapter() {
        collectRecyclerView.layoutManager=LinearLayoutManager(activity!!)
        collectRecyclerView.addItemDecoration(DividerItemDecoration(activity,DividerItemDecoration.VERTICAL))

    }
}